package cn.dansj.service;

import cn.dansj.entity.InterfaceInfo;
import org.springframework.data.domain.Page;

import java.util.List;
import java.util.Set;

public interface InterfaceInfoService {
    Page<InterfaceInfo> searchInterface(Integer pageNum,
                                        Integer pageLimit,
                                        String interfaceName,
                                        String url,
                                        String status,
                                        String method,
                                        String type,
                                        String apiType,
                                        String group);

    InterfaceInfo getInterface(String url, int status, String method);

    InterfaceInfo getBySequence(String sequence);

    InterfaceInfo getByName(String name);

    boolean checkInterfaceUrl(String sequence, String url);

    boolean checkInterfaceName(String sequence, String name);

    void save(InterfaceInfo interfaceInfo);

    List<InterfaceInfo> save(List<InterfaceInfo> interfaceInfoList);

    void updateStatus(String sequence, Integer status);

    int getTotalNum();

    List<InterfaceInfo> getAllInterface();

    long countForeignInterface();

    int deleteBySequence(String sequence);

    List<String> getAuthList();
}
